package routers

import (
	"github.com/gin-gonic/gin"
	jwt "github.com/golangblogs/gojwt"
	"week62/client/routers/handler"
)

func LoadApiRouter(r *gin.Engine) {
	r.POST("/login", handler.Login)
	r.POST("/sendSms", handler.SendSms)
	r.POST("/syncGoods", handler.SyncGoods)

	r.Use(jwt.JWTAuth("week62"))
	r.POST("/addOrder", handler.AddOrder)
}
